﻿<%@ Page Language="C#" Inherits="System.Web.Mvc.ViewPage<dynamic>" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<HEAD>
<TITLE></TITLE>
<link rel="stylesheet" href="../../Content/silver/menu.css" type="text/css" />
<META http-equiv="Content-Type" content="text/html; charset=utf-8">
<link rel="stylesheet" href="../../Content/silver/style.css" type="text/css" />
<script type="text/javascript" src="../../Scripts/jquery-1.7.min.js"></script>
<script type="text/javascript" src="../../Scripts/jquery.jclock.js"></script>
<script type="text/javascript">
    $(function () {

        $('#time').jclock({ withDate: true });
        //	$('#local').click(function(){$('#demo').jclock()});
        //	$('#with').click(function(){$('#demo').jclock({withDate:true, withWeek:true})});
        //$('#time').jclock({withDate:true, utc:true});
    });
</script>
<script type="text/javascript">
    $(document).ready(function () {
        timerReminder0 = setInterval("updateTime()", 120000);

    });



    function updateTime() {
        //alert(11);
        $.get("OnLine.aspx?d=" + Math.random(), { Action: "get" }, function (data, textStatus) {
            //alert(data);
            //var arr = data.split('|');
            if (data.indexOf('<span class="wendu">') > -1) {
                var arr = data.split('|');

                $('#xmname').html(arr[0]);
                $('#info').html("，" + arr[1]);
                if (isbaojing11) {
                    showBaoJing1();
                }
            }
            else {
                $('#info').html("");
            }
        });


    }

    var isbaojing11 = true;
    function showBaoJing1() {
        isbaojing11 = false;
        showBaoJing();
    }

    var isbaojing = true;
    function showBaoJing() {
        $('#baojingArea')[0].style.display = "block";

        if ($('#baojing')[0].style.color == '#fff') {
            $('#baojing')[0].style.color = "#FF0000";
        }
        else {
            $('#baojing')[0].style.color = "#fff";
        }
        if (isbaojing) {
            setTimeout("showBaoJing()", 500);
        }
        else {
            $('#baojingArea')[0].style.display = "none";
        }
    }

    function openBaoJing() {
        isbaojing = false;
        $('#baojingArea')[0].style.display = "none";
    }


</script>
<style type="text/css">
.xmname{ background:url(Styles/icon1/home.gif) no-repeat  -1px   ; padding-left:18px; height:24px; line-height:24px }
.time{ background:url(Styles/icon1/time.gif) no-repeat; padding-left:18px}
.wendu{ background:url(Styles/icon1/wendu.gif) no-repeat; padding-left:18px}
.fuzhao{ background:url(Styles/icon1/fuzhao.gif) no-repeat; padding-left:18px}
.fengsu{ background:url(Styles/icon1/fengsu.gif) no-repeat; padding-left:18px}
</style>
</HEAD>
<BODY style="margin-top:0px;">
<%
    User user = (User)ViewData["user"];
if (user == null)
{
%>
<script type="text/javascript">
    window.parent.location = "/Account/LogOn";
</script>
<%
    return;
}
%>
<TABLE cellSpacing=0 cellPadding=0 width="100%" border=0>
  <TBODY>
	<TR>
	  <TD rowspan="2" align="center" style="HEIGHT: 57px; width:180px;"><h1><%:user.Factory.Name %></h1></TD>
	  <TD colspan="2" style="PADDING-RIGHT: 10px; MARGIN-TOP: 0px; line-height:28px; height:28px; text-align:right;">&nbsp;
	  
	   <span  id="xmname"></span>
	  <span class="time"> 当前时间：<span id="time">2011-02-14 0:01</span></span>
	  <span  id="info"></span>
 
	  &nbsp; 
    
       </TD>
	</TR>
	<TR>
	  <TD style="width:70%"><div class="toptitle_r"></marquee></div></TD>
	  <TD align="right">
      <div class="toptitle_r">您好：<%:user.Name%>|<%:Html.ActionLink("退出", "Logoff", "Account", null, new { target = "_top"}) %></div>
      </TD>
	</TR>
	<TR>
	  <TD colspan="3" class="topline"></TD>
	</TR>
  </TBODY>
</TABLE>
 
</BODY>
</HTML>